import Vue from 'vue'
import Router from 'vue-router'

Vue.use(Router)


import homeContainer from '../components/tabbar/homeContainer.vue'
import memberContainer from '../components/tabbar/memberContainer.vue'
import shopcarContainer from '../components/tabbar/shopcarContainer.vue'
import searchContainer from '../components/tabbar/searchContainer.vue'

// 导入新闻列表组件
import newslist from '../components/news/newslist.vue'

export default new Router({
  routes: [   // 路由匹配规则
    {path: '/', redirect: '/home'},
    {path: '/home', component: homeContainer},
    {path: '/member', component: memberContainer},
    {path: '/shopcar', component: shopcarContainer},
    {path: '/search', component: searchContainer},
    {path: '/home/newslist', component: newslist}
  ],
  linkActiveClass: 'mui-active'
})
